﻿Option Strict On
Option Explicit On
Option Infer On

Imports System
Imports System.Linq
Imports System.Collections.Generic
Imports System.Xml.Linq
Imports Microsoft.VisualStudio.TestTools.UnitTesting
Imports GenDotNet.TemplateSupport
Imports GenDotNet.Task.Common
Imports GenDotNet.TemplateSupport.Strings
Imports <xmlns:orm="http://kadgen.com/KADORM.xsd">

'<TestClass()> _
'Public Class When_The_Input_Is_Standard
'   Inherits SqlBase

'   Private Const runSPName As String = "Select_StringValue"
'   Private Const literalString As String = " AND "
'   Private mStringValueTableColumns As IEnumerable(Of XElement)
'   Private testContextInstance As TestContext

'   Public Overrides ReadOnly Property Id() As System.Guid
'      Get
'         Return New Guid("{00A46197-CFCE-45a0-987F-8214F0D7AED5}")
'      End Get
'   End Property

'   Protected Overrides Function GetFileName(ByVal element As System.Xml.Linq.XElement) As String
'      ' NEWTEMPLATE: Update the following file name
'      Return element.@Name & ".sql"
'   End Function

'#Region "Setup and class level"
'   '''<summary>
'   '''Gets or sets the test context which provides
'   '''information about and functionality for the current test run.
'   '''</summary>
'   Public Property TestContext() As TestContext
'      Get
'         Return testContextInstance
'      End Get
'      Set(ByVal value As TestContext)
'         testContextInstance = value
'      End Set
'   End Property

'   <TestInitialize()> _
'   Public Sub MyClassInitialize(ByVal testContext As TestContext)
'      Dim xDoc = XDocument.Load("Standard.xml")
'      Dim xElement = (From runSp In xDoc...<orm:RunSp> Where runSp.@Name =runSPName ).SingleOrDefault
'      SetBaseElement(XElement)
'      Dim spSet = XElement.FirstAncestor(orm, "SPSet")
'      mStringValueTableColumns = From tableColumn In spSet...<orm:BuildRecordset>.<orm:TableColumn>
'      Me.SetUp()
'   End Sub

'   Protected Overrides Function GenerateFile() As String
'      Return String.Empty
'   End Function
'#End Region

'#Region "Open/Close Tests"
'   <TestMethod()> _
'   Public Sub Confirm_Opening()
'      Dim expected = IO.File.ReadAllText("SqlBaseTest_Confrim_Open.txt")
'      Dim actual = OutputOpening()
'      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   End Sub

'   <TestMethod()> _
'Public Sub Confirm_Close()
'      Dim expected = IO.File.ReadAllText("SqlBaseTest_Confrim_Close.txt")
'      Dim actual = OutputClose()
'      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   End Sub

'#End Region

'   '#Region "CommaEnding Tests"
'   '   <TestMethod()> _
'   '   Public Sub Confirm_CommaEnding_NotLast_NoWrap()
'   '      Dim par = mStringValueTableColumns(0)
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = False
'   '      Dim expected = commaString
'   '      Dim actual = CommaEnding(last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '   Public Sub Confirm_CommaEnding_Last_NoWrap()
'   '      Dim par = mStringValueTableColumns.Last
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = False
'   '      Dim expected = String.Empty
'   '      Dim actual = CommaEnding(last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '   Public Sub Confirm_CommaEnding_NotLast_Wrap()
'   '      Dim par = mStringValueTableColumns(0)
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = True
'   '      Dim expected = commaString & wrapString
'   '      Dim actual = CommaEnding(last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '   Public Sub Confirm_CommaEnding_Last_Wrap()
'   '      Dim par = mStringValueTableColumns.Last
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = True
'   '      Dim expected = String.Empty
'   '      Dim actual = CommaEnding(last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub
'   '#End Region

'   '#Region "LiteralEnding Tests"
'   '   <TestMethod()> _
'   '   Public Sub Confirm_LiteralEnding_NotLast_NoWrap()
'   '      Dim par = mStringValueTableColumns(0)
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = False
'   '      Dim expected = LiteralString
'   '      Dim actual = LiteralEnding(literalString, last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '  Public Sub Confirm_LiteralEnding_Last_NoWrap()
'   '      Dim par = mStringValueTableColumns.Last
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = False
'   '      Dim expected = String.Empty
'   '      Dim actual = LiteralEnding(literalString, last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '   Public Sub Confirm_LiteralEnding_NotLast_Wrap()
'   '      Dim par = mStringValueTableColumns(0)
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = True
'   '      Dim expected = LiteralString & wrapString
'   '      Dim actual = LiteralEnding(literalString, last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub

'   '   <TestMethod()> _
'   '   Public Sub Confirm_LiteralEnding_Last_Wrap()
'   '      Dim par = mStringValueTableColumns.Last
'   '      Dim last = mStringValueTableColumns.Last
'   '      Dim wrap = True
'   '      Dim expected = String.Empty
'   '      Dim actual = LiteralEnding(literalString, last, par, wrap)
'   '      Assert.AreEqual(expected, actual, "Incorrect Value Returned")
'   '   End Sub
'   '#End Region
'End Class
